//package com.tim.util;
//import com.monitorjbl.xlsx.StreamingReader;
//import org.apache.poi.ss.usermodel.Cell;
//import org.apache.poi.ss.usermodel.Row;
//
//import java.io.FileInputStream;
//import java.io.FileNotFoundException;
//import java.io.InputStream;
//
//public class XlsxStreamReader {
//    public static void main(String[] args) throws FileNotFoundException {
//        String filePath = "E:\\项目文件\\记录\\20241203 微信通道接入\\SUCCESS.xlsx";
//        FileInputStream in = new FileInputStream(filePath);
//        readBigExcel(in);
//    }
//    private static void readBigExcel(InputStream in) throws FileNotFoundException {
//        long start = System.currentTimeMillis();
//        StreamingReader reader = StreamingReader.builder()
//                .rowCacheSize(100)    // number of rows to keep in memory (defaults to 10)
//                .bufferSize(4096)     // buffer size to use when reading InputStream to file (defaults to 1024)
//                .sheetIndex(0)        // index of sheet to use (defaults to 0)
//                .read(in);            // InputStream or File for XLSX file (required)
//
//        for (Row r : reader) {
//            for (Cell c : r) {
//                System.out.print(c.getStringCellValue() + "  ");
//            }
//            System.out.println("\n"+(System.currentTimeMillis()-start));
//            System.out.println();
//        }
//    }
//
//}
